package com.tuzhi.test.sys.service;

import com.tuzhi.base.service.BaseService;
import com.tuzhi.test.sys.jpa.entity.SysDictionaryEntity;

import java.util.List;
import java.util.Map;

public interface SysDictionaryService extends BaseService<SysDictionaryEntity, Long> {

    final static String DATA_TYPE_LIST = "list";
    final static String DATA_TYPE_MAP = "map";
    final static String DATA_TYPE_STRING = "string";

    //list类型的值来源，key或者val
    final static String LIST_SOURCE_KEY = "key";
    final static String LIST_SOURCE_VAL = "val";



    public String find(String dicName);

    public List<String> findList(String dicName);

    public <T> List<T> findList(String dicName, String type, Class<T> c);

    public Map<String, String> findMap(String dicName);

    public <T> Map<String, T> findMap(String dicName, Class<T> c);

}
